package com.rockcent.service.impl;

import com.rockcent.mall.lib.domain.RockcentFund;
import com.rockcent.mall.lib.repository.RockcentFundRepository;
import com.rockcent.service.RockcentFundSrv;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * Created by zhangjh on 2017/3/10.
 */
@Service
public class RockcentFundSrvImpl implements RockcentFundSrv {
    @Autowired
    private RockcentFundRepository rockcentFundRepository;

    @Override
    public RockcentFund findOne(long id) {
        return rockcentFundRepository.findTop1ById(id);
    }

    @Override
    public void save(RockcentFund rockcentFund) {
        rockcentFundRepository.save(rockcentFund);
    }
}
